package com.lantosec.hmrp.modules.archives.vo;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.Date;
import java.util.List;

import com.lantosec.hmrp.modules.archives.entity.UserContract;
import com.lantosec.hmrp.core.mvc.BaseVO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * <p>
 * 合同信息表 VO对象
 * </p>
 *
 * @author AutoCode
 * @since 2020-06-09
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value="UserContract对象", description="合同信息表")
public class UserContractVO extends BaseVO<UserContract> {
    private static final long serialVersionUID = 1L;


    public UserContractVO(UserContract entity){
        this.userContractId = entity.getUserContractId();
        this.userId = entity.getUserId();
        this.contractNo = entity.getContractNo();
        this.deadline = entity.getDeadline();
        this.startDate = entity.getStartDate();
        this.endDate = entity.getEndDate();
        this.trialDeadline = entity.getTrialDeadline();
        this.trialStartDate = entity.getTrialStartDate();
        this.trialEndDate = entity.getTrialEndDate();
        this.compensation = entity.getCompensation();
        this.damage = entity.getDamage();
        this.attachment = entity.getAttachment();
        this.remark = entity.getRemark();
        this.createId = entity.getCreateId();
        this.createUser = entity.getCreateUser();
        this.createTime = entity.getCreateTime();
        this.verifyId = entity.getVerifyId();
        this.verifyUser = entity.getVerifyUser();
        this.verifyTime = entity.getVerifyTime();
        this.verifyStatus = entity.getVerifyStatus();
    }

    @Override
    public UserContract convertToEntity(){
        return new UserContract(this);
    }


    @ApiModelProperty(value = "合同ID")
    private String userContractId;

    @ApiModelProperty(value = "user主表ID")
    private String userId;

    @ApiModelProperty(value = "合同编号")
    private String contractNo;

    @ApiModelProperty(value = "合同期限（月）")
    private Integer deadline;

    @ApiModelProperty(value = "合同开始时间")
    private String startDate;

    @ApiModelProperty(value = "合同结束时间")
    private String endDate;

    @ApiModelProperty(value = "试用期限（月）")
    private Integer trialDeadline;

    @ApiModelProperty(value = "试用开始时间")
    private String trialStartDate;

    @ApiModelProperty(value = "试用结束时间")
    private String trialEndDate;

    @ApiModelProperty(value = "经济补偿金")
    private BigDecimal compensation;

    @ApiModelProperty(value = "赔偿金")
    private BigDecimal damage;

    @ApiModelProperty(value = "合同附件")
    private String attachment;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "创建人ID")
    private String createId;

    @ApiModelProperty(value = "创建人姓名")
    private String createUser;

    @ApiModelProperty(value = "创建时间")
    private Date createTime;

    @ApiModelProperty(value = "审核人ID")
    private String verifyId;

    @ApiModelProperty(value = "审核人姓名")
    private String verifyUser;

    @ApiModelProperty(value = "审核时间")
    private Date verifyTime;

    @ApiModelProperty(value = "审核状态（0：未审核，1：以审核）")
    private Integer verifyStatus;

    @ApiModelProperty(value = "附件路径")
    private List<String> savePath;
    @ApiModelProperty(value = "审核状态")
    private Integer state;
}
